package com.yaowk.weixin.kit;

import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;

/**
 * @authc yaowk
 * 2017/7/18
 */
public class WeixinKit {

    /**
     * UTF-8编码
     *
     * @param source
     * @return
     */
    public static String urlEncodeUTF8(String source) {
        try {
            return URLEncoder.encode(source, "UTF-8");
        } catch (UnsupportedEncodingException e) {
            throw new RuntimeException(e);
        }
    }


}
